<?php
namespace app\admin\model;
use think\Model;
use think\Db;

/**
 * 新短信模板
 * @package app\admin\model
 */
class BusSmsCtn extends Model
{
    public static function getList($request)
    {
        $where = [];
        if(!empty($request['ctn'])) {
            $where[]  = ['sms_ctn','like', '%' . $request['ctn'] . '%'];
        }

        return self::where($where)->paginate($request['limit'], false,['query' => $request]);
    }

    public static function add($data)
    {
        return self::create($data);
    }
}